package com.zbj.consul.provider;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * ConsulProviderController
 *
 * @author weigang
 * @create 2019-08-10
 **/
@RestController
@RequestMapping("/consul/provider")
public class ConsulProviderController {

    @Value("${server.port}")
    private Integer port;

    @RequestMapping(value = "/hello", method = {RequestMethod.GET})
    public String hello(String world) {
        return "hello " + world + " " + port;
    }
}